﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MS.InformationManagement.DAL.DTOs;

namespace MS.InformationManagement.DAL.Support.EqualityComparers
{
    public class UserDTOEqualityComparer:IEqualityComparer<UserDTO>
    {
        public bool Equals(UserDTO x, UserDTO y)
        {
            return x.DisplayName.Equals(y.DisplayName) && x.LoginName.Equals(y.LoginName);
        }

        public int GetHashCode(UserDTO obj)
        {
            return obj.LoginName.GetHashCode();
        }
    }
}
